<template>
  <div>
    <Container>
      <GoodsItem :goods="goods"></GoodsItem>
    </Container>
  </div>
</template>
<script>
import Container from "../../../components/container/Container"; //引入容器组件
import GoodsItem from "../../../components/goodsList/GoodsItem"; //引入人气推荐组件
export default {
  data() {
    return {
      goods: [],
    };
  },
  components: {
    Container, //容器组件
    GoodsItem, //人气推荐组件
  },
  mounted() {
    // 商品列表数据
    this.$APIShow
      .shop()
      .then((res) => {
        // console.log(res.data.data);
        this.goods = res.data.data;
        // console.log(this.goods);
      })
      .catch((err) => {
        console.log(err);
      });
  },
};
</script>
<style lang="scss" scoped>
</style>